#{extends 'main.html' /}
#{set title:'Videos' /}

<div class="series_tab">
<div class="series_title">${series?.name}</div>
<div class="series_follow">
#{if user?.follows?.contains(series)}
	<img src="@{'/public/images/remove_icon.png'}" width="14" height="14" border="0" style="vertical-align:middle;" /> 
	<a href="/s/${series?.id}/unfollow">Unfollow</a>
#{/if}
#{else}
<img src="@{'/public/images/plus_icon.gif'}" width="14" height="14" border="0" style="vertical-align:middle;" /> 
    <a href="/s/${series?.id}/follow">Follow</a>
#{/else}
</div>
<div class="series_follow">
	<img src="@{'/public/images/facebookShareIcon.png'}" width="14" height="14" border="0" style="vertical-align:middle;" />
	<a href=""  onclick="postToFeed('${series?.name} @ TV World', 'http://54.246.83.207:9007${series?.poster}', '${user?.name} follows ${series?.name}', '${series?.name} @ TV World', 'http://apps.facebook.com/cengdoi-gg/s/${series?.id}',''); return false;">Share</a>
</div>
</div>

<div class="clear" style="height: 10px;"></div>

<div class="series_menu">
<a href="/s/${series?.id}" class="series_menu_a">Details</a> 
<a href="/s/${series?.id}/topics" class="series_menu_a">Topics</a> 
<a href="/s/${series?.id}/videos" class="series_menu_a_active">Videos</a> 
<a href="/s/${series?.id}/episodes" class="series_menu_a">Episodes</a>
</div>

<div class="clear" style="height: 10px;"></div>

<div class="videos">
	<div class="add_a_video">
		<img src="@{'/public/images/video-add.gif'}" width="16" height="16" border="0" style="vertical-align:middle;" /> 
		<a href="/s/${series?.id}/addvideo">Add Video</a></div>
	<div class="clear"></div>
	
#{paginate.list items:paginator, as:'video'}
	<div class="video">
		<a href="/s/${series?.id}/video/${video?.id}">
			<img src="http://img.youtube.com/vi/${video?.address}/1.jpg" width="120" height="90" ><br />
			${video?.name}
		</a> 
	</div>
#{/paginate.list} 

<div class="clear" style="height:20px;"></div>
#{paginate.controls items:paginator /}

	<div class="clear"></div>
</div>

